﻿using System.Data;
using DAL;

namespace BO.Photo
{
    public class PhotoBO_NoCache : IPhotoBO
    {
        private static PhotoBO_NoCache _ownerInstance;
        public static PhotoBO_NoCache GetInstance()
        {
            return _ownerInstance ?? (_ownerInstance = new PhotoBO_NoCache());
        }

        public DataTable GetPhotosInNews(long newsId, int top)
        {
            DataTable dt;
            using (var db = new MainDB())
            {
                dt = db.StoredProcedures.GetPhotosInNews(newsId, top);
            }
            return dt;
        }
    }
}
